# Maintainer: Alexey Pavlov <alexpux@gmail.com>

_realname=HTTP-Daemon
pkgname=perl-${_realname}
pkgver=6.01
pkgrel=2
pkgdesc="A simple http server class"
arch=('any')
url="http://search.cpan.org/dist/HTTP-Daemon"
groups=('perl-modules')
license=('PerlArtistic' 'GPL')
depends=('perl' 'perl-HTTP-Date' 'perl-HTTP-Message' 'perl-LWP-MediaTypes')
options=('!emptydirs')
source=(https://www.cpan.org/authors/id/G/GA/GAAS/${_realname}-${pkgver}.tar.gz)
sha256sums=('43fd867742701a3f9fcc7bd59838ab72c6490c0ebaf66901068ec6997514adc2')

build() {
  cd "${srcdir}/${_realname}-${pkgver}"
  perl Makefile.PL INSTALLDIRS=vendor
  make
}

check() {
  cd "${srcdir}/${_realname}-${pkgver}"
  make test
}

package() {
  cd "${srcdir}/${_realname}-${pkgver}"
  make DESTDIR="${pkgdir}" install
}
